/*
 *
 *  * Copyright (c) 2016. For Intelligent Group.
 *
 */

package com.intelligent.ispc.client.core.validator;

import com.intelligent.ispc.client.utils.binding.AbstractBean;
import javax.validation.constraints.Pattern;

/**
 * Created by tony.yu on 2016/9/9.
 */
public class UslAndLslDto extends AbstractBean {
    public static final String PROPERTYNAME_USL = "uslValue";
    public static final String PROPERTYNAME_LSL = "lslValue";

    @Pattern(regexp = "(-?\\d+(\\.\\d+)?)?", message = "Must input numbers")
    private String uslValue;

    @Pattern(regexp = "(-?\\d+(\\.\\d+)?)?", message = "Must input numbers")
    private String lslValue;

    public String getUslValue() {
        return uslValue;
    }

    /**
     * Set the USL's value
     *
     * @param uslValue uslValue
     */
    public void setUslValue(String uslValue) {
        firePropertyChange(PROPERTYNAME_USL, this.uslValue, this.uslValue = uslValue);
    }

    public String getLslValue() {
        return lslValue;
    }

    /**
     * Set the LSL's value
     *
     * @param lslValue lslValue
     */
    public void setLslValue(String lslValue) {
        firePropertyChange(PROPERTYNAME_LSL, this.lslValue, this.lslValue = lslValue);
    }
}
